package scuts.core;
/**
 * ...
 * @author 
 */

class Flip2 {
	public static function flip < A, B, C > (f:A->B->C):B->A->C
	{
		return function (b, a) return f(a, b);
	}
}

class Flip3 {
	public static function flip < A, B, C, D > (f:A->B->C->D):B->A->C->D
	{
		return function (b, a, c) return f(a, b, c);
	}
}

class Flip4 {
	public static function flip < A, B, C, D, E > (f:A->B->C->D->E):B->A->C->D->E
	{
		return function (b, a, c, d) return f(a, b, c, d);
	}
}

class Flip5 {
	public static function flip < A, B, C, D, E, F > (f:A->B->C->D->E->F):B->A->C->D->E->F
	{
		return function (b, a, c, d, e) return f(a, b, c, d, e);
	}
}